package com.apestech.framework.sql.modul;

public class VarPos {
	
	private int start;
	private int end;
	private int lastEnd;
	private String var;
	private String symbol;
	private Object value;
	private String tab;
	private String fieldValue;
	private String notNull;
	private String fieldType;
	private String treeTable;
	private String treeId;
	private String treePId;

	/*

	String fieldValue=null;
			String notNull=null;
			String dateCol=null;
			String procType=null;
			String fieldType=null;

	if(dict!=null){
					JSONObject vmap=(JSONObject) dict.get(key);
					if(vmap!=null){
						fieldType=vmap.getString("TYPE_NAME");
		                fieldValue=vmap.getString("COLUMN_DEF");
		                notNull=dict.getString("NOTNULL");
		                dateCol=dict.getString("DATE_COLUMN");
		                procType=dict.getString("TYPE");
					}
				}

	singleValue.setVar(tabName, key, value, fieldType, fieldValue, notNull);

	*/
	
	public String getSymbol() {
		return symbol;
	}

	public void setSymbol(String symbol) {
		this.symbol = symbol;
	}

	public void setValue(Object value) {
		this.value = value;
	}

	public int getStart() {
		return start;
	}

	public void setStart(int start) {
		this.start = start;
	}

	public int getEnd() {
		return end;
	}

	public int getLastEnd() {
		return lastEnd;
	}

	public void setEnd(int end) {
		this.end = end;
	}

	public String getVar() {
		return var;
	}

	public String getTab() {
		return tab;
	}

	public Object getValue() {
		return value;
	}

	public String getFieldValue() {
		return fieldValue;
	}

	public String getNotNull() {
		return notNull;
	}

	public String getFieldType() {
		return fieldType;
	}

	public void setInfo(int start, int end, int lastEnd, String var, String symbol, String tab, Object value, String fieldType, String fieldValue, String notNull){
		this.start=start;
		this.end=end;
		this.lastEnd=lastEnd;
		this.var=var;
		this.symbol=symbol;
		this.tab=tab;
		this.value=value;
		this.fieldValue=fieldValue;
		this.notNull=notNull;
		this.fieldType=fieldType;
	}

	public void setTree(String treeTable, String treeId, String treePId) {
		this.treeTable=treeTable;
		this.treePId=treePId;
		this.treeId=treeId;
	}
	
	public String toString(){
		return "{lastEnd:"+lastEnd+", start:"+start+", end:"+end+", tab:"+tab+", var:"+var+", symbol:"+symbol+"}\n";
	}

}
